﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Forms;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using TDTool.Collections;
using TDTool.Utils;

namespace TDTool
{
    /// <summary>
    /// MainWindow.xaml 的交互逻辑
    /// </summary>
    public partial class MainWindow : Window
    {
        public MainWindow()
        {
            InitializeComponent();

            this.Loaded += MainWindow_OnLoaded;
        }

        private void GoTD_Click(object sender, RoutedEventArgs e)
        {
            new TdTableWindow().Show();
            this.Close();
        }
        private void GoRocket_Click(object sender, RoutedEventArgs e)
        {
            new RocketWindow().Show();
            this.Close();
        }




        #region 全局快捷键
        private void MainWindow_OnLoaded(object sender, RoutedEventArgs e)
        {
            HotKey hot = new HotKey(this, HotKey.KeyFlags.MOD_CONTROLALT, Keys.M);
            hot.OnHotKey += hot_OnHotKey;
        }

        void hot_OnHotKey()
        {
            System.Windows.MessageBox.Show("我是按ctrl+alt+m 进来的!");
        }
        #endregion 
    }
}
